class BarController {
  async foo(ctx) {
    const users = await ctx.db.User.findAll()
    ctx.body = { users }
  }

  async bar(ctx) {
    const { name } = ctx.request.body

    const user = await ctx.db.User.create({
      name,
    })

    ctx.body = { user }
  }
}

module.exports = new BarController()